package com.yboot.starter.mybatis.core.base.entity;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.yboot.starter.common.core.web.validation.UpdateGroup;
import lombok.Data;

import javax.validation.constraints.NotNull;
import java.io.Serializable;

/**
 * ID基础实体类
 *
 * @author yangcs
 * @date 2025/8/15
 */
@Data
public class BaseIdEntity extends Model implements Serializable {
    private static final long serialVersionUID = 1L;

    @TableId
    @NotNull(message = "id不能为空", groups = {UpdateGroup.class})
    private String id;
}